{{--复选框组件 --}}
<div class="layui-form-item" >
    <label class="layui-form-label">@if($must??true)<span style="color:red">*</span>@endif{{ $label??'复选框' }}</label>
    <div class="layui-input-block" style="border: 1px solid #e6e6e6;max-height: 100px;overflow:auto">
        @forelse($val as $k=>$item)
            <input type="checkbox" name="{{ $name??'checkbox' }}" title="{{ $item??'title' }}" value="{{ $k??'' }}" lay-skin="{{ $style??'' }}" @if($readonly??false) readonly @endif  @if(isset($checked)&&in_array($k,$checked)) checked @endif>
        <br>
        @empty
            暂无选项
        @endforelse
    </div>
</div>

@section('css')
    @parent
    <style>
        .layui-form-pane .layui-form-checkbox {
            margin: 3px 0 3px 10px;
        }
    </style>
@endsection